package com.fnzx.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.fnzx.entity.DemandEntity;
import com.fnzx.entity.ProjectEntity;
import com.fnzx.entity.RelationEntity;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface DemandDao extends BaseMapper<DemandEntity> {

    @Select("select * from project where demand_id=#{demandId}")
    public List<ProjectEntity> getGuan(@Param("demandId") Long demandId);

    @Select("select * from relation where tb_source =\"demand.category_id\"")
    public List<RelationEntity> getFen();
}
